package controllers

import (
	"fmt"
	"github.com/astaxie/beego"
)

type ProjectController struct {
	beego.Controller
}
type ProjectBaseInfo struct {
	ProjectNumber string `json:"projectNumber"`
	ProjectId     int `json:"projectID"`
}

// @Title base info
// @Description create users
// @Param	body		body 	models.User	true		"body for user content"
// @Success 200 {int} models.User.Id
// @Failure 403 body is empty
// @router / [get]
func (p *ProjectController) BaseInfoByProjectID(projectId int) {

	projectNum := p.GetString("projectNum")
	//body := [...]string{
	//	projectNum,
	//}
	//mapBody := map[string]string{
	//	"projectNumber": projectNum,
	//	"projectID":     "hello world",
	//}
	baseInfo := ProjectBaseInfo{
		projectNum,
		projectId,
	}
	fmt.Println(baseInfo)
	p.Data["json"] = &baseInfo
	p.ServeJSON()
}
